<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.3"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>TrackerControl: net.kollnig.missioncontrol.Common Class Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectlogo"><img alt="Logo" src="ic_launcher_round.png"/></td>
  <td id="projectalign">
   <div id="projectname">TrackerControl
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.3 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search",'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><b>net</b></li><li class="navelem"><b>kollnig</b></li><li class="navelem"><b>missioncontrol</b></li><li class="navelem"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html">Common</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="summary">
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="classnet_1_1kollnig_1_1missioncontrol_1_1_common-members.html">List of all members</a>  </div>
  <div class="headertitle"><div class="title">net.kollnig.missioncontrol.Common Class Reference</div></div>
</div><!--header-->
<div class="contents">
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-static-methods" name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:a98d8180ac89ff3453bf5b4ea7f5fc52f"><td class="memItemLeft" align="right" valign="top">static String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a98d8180ac89ff3453bf5b4ea7f5fc52f">fetch</a> (String url)</td></tr>
<tr class="separator:a98d8180ac89ff3453bf5b4ea7f5fc52f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeaef5f9d024a9ec5eb031c35b1026d7d"><td class="memItemLeft" align="right" valign="top">static Intent&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#aeaef5f9d024a9ec5eb031c35b1026d7d">adSettings</a> ()</td></tr>
<tr class="separator:aeaef5f9d024a9ec5eb031c35b1026d7d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4646ec4c16f6ddb8a933dd77f3942732"><td class="memItemLeft" align="right" valign="top">static Intent&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a4646ec4c16f6ddb8a933dd77f3942732">browse</a> (String url)</td></tr>
<tr class="separator:a4646ec4c16f6ddb8a933dd77f3942732"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4bec1156937743d99f92ecd871672109"><td class="memItemLeft" align="right" valign="top">static boolean&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a4bec1156937743d99f92ecd871672109">hasAdSettings</a> (Context c)</td></tr>
<tr class="separator:a4bec1156937743d99f92ecd871672109"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2b66bdc56e37467b3b8f0dfc769dbda1"><td class="memItemLeft" align="right" valign="top">static Intent&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a2b66bdc56e37467b3b8f0dfc769dbda1">emailIntent</a> (@Nullable String email, String subject, String body)</td></tr>
<tr class="separator:a2b66bdc56e37467b3b8f0dfc769dbda1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a34b0dbca6fcca82a0ab416ede73399d9"><td class="memItemLeft" align="right" valign="top">static boolean&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a34b0dbca6fcca82a0ab416ede73399d9">isCallable</a> (Context c, Intent intent)</td></tr>
<tr class="separator:a34b0dbca6fcca82a0ab416ede73399d9"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a921fa689663100763bf1845191c808fb"><td class="memItemLeft" align="right" valign="top">static String&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a921fa689663100763bf1845191c808fb">getAppName</a> (PackageManager pm, int uid)</td></tr>
<tr class="separator:a921fa689663100763bf1845191c808fb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a56996f31baaa8150aa81db4e1ba9f640"><td class="memItemLeft" align="right" valign="top">static Intent&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a56996f31baaa8150aa81db4e1ba9f640">getLaunchIntent</a> (Activity activity, String appId)</td></tr>
<tr class="separator:a56996f31baaa8150aa81db4e1ba9f640"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9e5f0110795c381dff5cfee0ead49f39"><td class="memItemLeft" align="right" valign="top">static Snackbar&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a9e5f0110795c381dff5cfee0ead49f39">getSnackbar</a> (Activity activity, int msg)</td></tr>
<tr class="separator:a9e5f0110795c381dff5cfee0ead49f39"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1f311882f1a8b42da640c1e05f0ab534"><td class="memItemLeft" align="right" valign="top">static int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classnet_1_1kollnig_1_1missioncontrol_1_1_common.html#a1f311882f1a8b42da640c1e05f0ab534">dayOfYear</a> ()</td></tr>
<tr class="separator:a1f311882f1a8b42da640c1e05f0ab534"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="aeaef5f9d024a9ec5eb031c35b1026d7d" name="aeaef5f9d024a9ec5eb031c35b1026d7d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aeaef5f9d024a9ec5eb031c35b1026d7d">&#9670;&nbsp;</a></span>adSettings()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static Intent net.kollnig.missioncontrol.Common.adSettings </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Returns an intent to the system ad settings</p>
<dl class="section return"><dt>Returns</dt><dd>Intent to open system ad settings </dd></dl>

</div>
</div>
<a id="a4646ec4c16f6ddb8a933dd77f3942732" name="a4646ec4c16f6ddb8a933dd77f3942732"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4646ec4c16f6ddb8a933dd77f3942732">&#9670;&nbsp;</a></span>browse()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static Intent net.kollnig.missioncontrol.Common.browse </td>
          <td>(</td>
          <td class="paramtype">String&#160;</td>
          <td class="paramname"><em>url</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Returns an intent to open a URL in a browser</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">url</td><td>A URL to be opened </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>An intent to open the provided URL </dd></dl>

</div>
</div>
<a id="a1f311882f1a8b42da640c1e05f0ab534" name="a1f311882f1a8b42da640c1e05f0ab534"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1f311882f1a8b42da640c1e05f0ab534">&#9670;&nbsp;</a></span>dayOfYear()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static int net.kollnig.missioncontrol.Common.dayOfYear </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Computes the current day of year</p>
<dl class="section return"><dt>Returns</dt><dd>The current day of year </dd></dl>

</div>
</div>
<a id="a2b66bdc56e37467b3b8f0dfc769dbda1" name="a2b66bdc56e37467b3b8f0dfc769dbda1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2b66bdc56e37467b3b8f0dfc769dbda1">&#9670;&nbsp;</a></span>emailIntent()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static Intent net.kollnig.missioncontrol.Common.emailIntent </td>
          <td>(</td>
          <td class="paramtype">@Nullable String&#160;</td>
          <td class="paramname"><em>email</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">String&#160;</td>
          <td class="paramname"><em>subject</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">String&#160;</td>
          <td class="paramname"><em>body</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Returns intent to write an email with an email app</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">email</td><td>The recipient email address </td></tr>
    <tr><td class="paramname">subject</td><td>The subject line </td></tr>
    <tr><td class="paramname">body</td><td>The email body </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The intent </dd></dl>

</div>
</div>
<a id="a98d8180ac89ff3453bf5b4ea7f5fc52f" name="a98d8180ac89ff3453bf5b4ea7f5fc52f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a98d8180ac89ff3453bf5b4ea7f5fc52f">&#9670;&nbsp;</a></span>fetch()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static String net.kollnig.missioncontrol.Common.fetch </td>
          <td>(</td>
          <td class="paramtype">String&#160;</td>
          <td class="paramname"><em>url</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Downloads content from a provided URL</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">url</td><td>URL for download </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Downloaded content </dd></dl>

</div>
</div>
<a id="a921fa689663100763bf1845191c808fb" name="a921fa689663100763bf1845191c808fb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a921fa689663100763bf1845191c808fb">&#9670;&nbsp;</a></span>getAppName()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static String net.kollnig.missioncontrol.Common.getAppName </td>
          <td>(</td>
          <td class="paramtype">PackageManager&#160;</td>
          <td class="paramname"><em>pm</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>uid</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Retrieves the name of the app based on the given uid</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">uid</td><td>- of the app </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>the name of the package of the app with the given uid, or "Unknown" if no name could be found for the uid. </dd></dl>

</div>
</div>
<a id="a56996f31baaa8150aa81db4e1ba9f640" name="a56996f31baaa8150aa81db4e1ba9f640"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a56996f31baaa8150aa81db4e1ba9f640">&#9670;&nbsp;</a></span>getLaunchIntent()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static Intent net.kollnig.missioncontrol.Common.getLaunchIntent </td>
          <td>(</td>
          <td class="paramtype">Activity&#160;</td>
          <td class="paramname"><em>activity</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">String&#160;</td>
          <td class="paramname"><em>appId</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Returns launch intent for a provided app</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">activity</td><td>The current activity </td></tr>
    <tr><td class="paramname">appId</td><td>Package name of the app to be launched </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>An intent </dd></dl>

</div>
</div>
<a id="a9e5f0110795c381dff5cfee0ead49f39" name="a9e5f0110795c381dff5cfee0ead49f39"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9e5f0110795c381dff5cfee0ead49f39">&#9670;&nbsp;</a></span>getSnackbar()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static Snackbar net.kollnig.missioncontrol.Common.getSnackbar </td>
          <td>(</td>
          <td class="paramtype">Activity&#160;</td>
          <td class="paramname"><em>activity</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>msg</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Computes a message in a snackbar to be shown to user.</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">activity</td><td>The current activity </td></tr>
    <tr><td class="paramname">msg</td><td>The message to be shown </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The computed snackbar. Displayed with .show() </dd></dl>

</div>
</div>
<a id="a4bec1156937743d99f92ecd871672109" name="a4bec1156937743d99f92ecd871672109"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4bec1156937743d99f92ecd871672109">&#9670;&nbsp;</a></span>hasAdSettings()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static boolean net.kollnig.missioncontrol.Common.hasAdSettings </td>
          <td>(</td>
          <td class="paramtype">Context&#160;</td>
          <td class="paramname"><em>c</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Check if system ad settings exist</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">c</td><td>Context </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Information if system ad settings exist </dd></dl>

</div>
</div>
<a id="a34b0dbca6fcca82a0ab416ede73399d9" name="a34b0dbca6fcca82a0ab416ede73399d9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a34b0dbca6fcca82a0ab416ede73399d9">&#9670;&nbsp;</a></span>isCallable()</h2>

<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">static boolean net.kollnig.missioncontrol.Common.isCallable </td>
          <td>(</td>
          <td class="paramtype">Context&#160;</td>
          <td class="paramname"><em>c</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">Intent&#160;</td>
          <td class="paramname"><em>intent</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">static</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">
<p >Checks if intent exists</p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramname">c</td><td>Content </td></tr>
    <tr><td class="paramname">intent</td><td>Intent </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>Information if intent exists </dd></dl>

</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>app/src/main/java/net/kollnig/missioncontrol/Common.java</li>
</ul>
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.3
</small></address>
</body>
</html>
